import type { TableColums, FormItemRows } from '@meetjs/element-plus-kit'

// 表格列配置
export const tableColumns: TableColums[] = [
	{
		prop: 'rewardTime',
		label: '奖罚时间',
		minWidth: 120,
		align: 'center'
	},
	{
		prop: 'rewardContent',
		label: '奖罚内容',
		minWidth: 200,
		align: 'center'
	},
	{
		prop: 'rewardQuality',
		label: '奖罚性质',
		minWidth: 100,
		align: 'center'
	},
	{
		prop: 'remark',
		label: '备注',
		minWidth: 150,
		align: 'center'
	},
	{
		prop: 'action',
		label: '操作',
		width: 160,
		fixed: 'right',
		align: 'center'
	}
]

// 表单配置
export const formOptions: FormItemRows[] = [
	{
		type: 'date-picker',
		label: '奖罚时间',
		prop: 'rewardTime',
		required: true,
		attrs: {
			type: 'date',
			placeholder: '请选择奖罚时间',
			format: 'YYYY-MM-DD',
			'value-format': 'YYYY-MM-DD'
		}
	},
	{
		type: 'textarea',
		label: '奖罚内容',
		prop: 'rewardContent',
		required: true,
		attrs: {
			placeholder: '请输入奖罚内容',
			rows: 4,
			maxlength: 500,
			'show-word-limit': true
		}
	},
	{
		type: 'input',
		label: '奖罚性质',
		prop: 'rewardQuality',
		required: true,
		attrs: {
			clearable: true
		}
	},
	{
		type: 'textarea',
		label: '备注',
		prop: 'remark',
		attrs: {
			placeholder: '请输入备注信息',
			rows: 3,
			maxlength: 500,
			'show-word-limit': true
		}
	}
]
